package com.metro.outsourced.filemng.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import java.util.Date;

/**
 * @author yaod
 * @Description  文件记录
 */
@Data
@TableName("t_file_record")
public class FileRecordEntity {

    /**
     * 主键id
     */
    @TableId(
            value = "file_id",
            type = IdType.ASSIGN_UUID
    )
    private String fileId;


    /**
     * 文件真实路径
     */
    private String filePath;

    /**
     * 文件名称
     */
    private String fileName;

    /**
     * 上传时间
     */
    private Date uploadTime;

    /**
     * 业务id
     */
    private String objId;

    /**
     * 是否删除
     */
    private Integer isDel;

    /**
     * 删除时间
     */
    private String delTime;

    public FileRecordEntity(String filePath,String fileName,String objId){
        this.filePath = filePath;
        this.fileName = fileName;
        this.objId = objId;
        this.uploadTime = new Date();
        this.isDel = 0;
    }

    public FileRecordEntity() {
    }
}
